import React from "react";

export default function Footer(props) {
  const { setCount } = props;

  //事件函数
  const changeCount = () => {
    setCount((x) => x + 1);
  };

  return (
    <div>
      <h2>Footer</h2>
      <button onClick={changeCount}>修改count</button>
    </div>
  );
}
